<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    
<html>

<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-language" content="en" />
<meta name="Keywords" content="progress,ant,compilation,automated,task,querret,apache,build tools,roundtable" />
<meta name="Description" content="PCT is set of ANT tasks designed to compile Progress procedures among others things" />
<meta name="revisit-after" content="30 days" />
<meta name="DC.Language" content="en" />
<title>PCT documentation - R-Code structure</title>
<link rel="stylesheet" type="text/css" href="style.css" media="screen" title="Normal" />
</head>
<body>

<div class="Main">

<div class="Bandeau">
  <span id="sflogo">
    <a href="http://sourceforge.net"><img id="sflogoimg" alt="SourceForge.net Logo" height="31" width="88" src="http://sourceforge.net/sflogo.php?group_id=%3Cb%3E85743%3C/b%3E&amp;amp;type=1"/></a>
  </span>
  Progress&reg; OpenEdge&reg; Compilation Tools
</div>

<div class="Menu">
  <a href="index.html">Overview</a>
  :: <a href="download.html">Download</a>
  :: <a href="screenshots.html">Screenshots</a>
  :: <span class="selected">Documentation</span>
  :: <a href="javadoc/index.html">JavaDoc</a>
  :: <a href="links.html">Links</a>
</div>

@RIGHT_BANNER@

<div class="Text">
<h1>Overview</h1>
<p>
This is a description of r-code file format. It's just an attempt based on guessing the content of a file.
</p>
<pre>
+-----------------------------------+
| Object header                     |
+-----------------------------------+
| Segments location table           |
+-----------------------------------+
| Initial value segment             |
+-----------------------------------+
| Action code segment (MAIN)        |
+-----------------------------------+
| ECode segment (1 to 4)            |
+-----------------------------------+
| Action code segment (procedures)  |
+-----------------------------------+
| One segment per frame             |
+-----------------------------------+
| One segment par language          |
+-----------------------------------+
| Debugger segment                  |
+-----------------------------------+
</pre>
Object header overview :
<table cellpadding="2">
<tr>
<th colspan="3">Header (68 bytes long)</th>
</tr>
<tr>
<th>Offset</th>
<th>Size (in bytes)</th>
<th>Description</th>
</tr>
<tr>
<td align="center">0x00</td>
<td align="center">4</td>
<td>Magic number : either 0x56CED309 or 0x09D3CE56</td>
</tr>
<tr>
<td align="center">0x04</td>
<td align="center">4</td>
<td>Timestamp : in seconds since 1/1/1970</td>
</tr>
<tr>
<td align="center">0x08</td>
<td align="center">2</td>
<td>Procedures list segment size</td>
</tr>
<tr>
<td align="center">0x0A</td>
<td align="center">2</td>
<td>Unknown (always 0xF000)</td>
</tr>
<tr>
<td align="center">0x0C</td>
<td align="center">2</td>
<td>Unknown</td>
</tr>
<tr>
<td align="center">0x0E</td>
<td align="center">2</td>
<td>Compiler version</td>
</tr>
<tr>
<td align="center">0x1E</td>
<td align="center">4</td>
<td>Segments location size</td>
</tr>
</table>

<table cellpadding="2">
<tr>
<th colspan="3">Procedures list segment (starting at offset 0x44) -- Length is found in header</th>
</tr>
<tr>
<th>Offset</th>
<th>Size (in bytes)</th>
<th>Description</th>
</tr>
<tr>
<td align="center">0x00</td>
<td align="center">8</td>
<td>Unknown</td>
</tr>
<tr>
<td align="center">0x08</td>
<td align="center">Procedures list size - 8 bytes</td>
<td>Only available if file is compiled with minSize=FALSE. String with separator 0x00. First entry is codepage, next entries are for each procedure/function contained in the file.
Each entry is made of strings (separator ,) ; first one is [MAIN|PROCEDURE|FUNCTION|DLL-ENTRY] identifier, second one is return type,
next ones are parameters. Encoding may be skipped if there are no strings in rcode.
</td>
</tr>
</table>

<table cellpadding="2">
<tr>
<th colspan="3">Segments list (starting at offset 0x44 + Action code segment size) -- Length is found in header</th>
</tr>
<tr>
<th>Offset</th>
<th>Size (in bytes)</th>
<th>Description</th>
</tr>
<tr>
<td align="center">0x00</td>
<td align="center">8</td>
<td>ISegment</td>
</tr>
<tr>
<td align="center">0x08</td>
<td align="center">Action segment size minus 8 bytes</td>
<td>String with separator 0x00. First entry is codepage, next entries are for each procedure/function contained in the file.
Each entry is made of strings (separator ,) ; first one is [MAIN|PROCEDURE|FUNCTION|DLL-ENTRY] identifier, second one is return type,
next ones are parameters (
</td>
</tr>
</table>


</div>

</div>
@ANALYTICS@</body>

</html>
